package com.tool.write.entity;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.alibaba.excel.annotation.format.NumberFormat;
import com.tool.write.simple.CustomStringStringConverter;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.Setter;

import java.util.Date;

/**
 * @author niuyicong
 * @date 2024/10/18  18:26:40
 * @description
 */
@Getter
@Setter
@AllArgsConstructor
public class PersonConverterData {
    @ExcelProperty(value = "姓名",converter = CustomStringStringConverter.class )
    private String name;
    @ExcelProperty(value = "年龄")
    private Integer age;
    @DateTimeFormat("yyyy年MM月dd日HH时mm分ss秒")
    @ExcelProperty(value = "生日")
    private Date birthDay;
    @NumberFormat("#.##%")
    @ExcelProperty(value = "薪水")
    private Double salary;
    @ExcelIgnore
    private String gender;
}
